/*
 * Powered By [Transnal ES Framework]
 * Web Site: http://www.transnal.com
 * Copyright (c) 2010 - 2018
 */
package com.quanquan.repository;

import com.quanquan.entity.StudentLesson;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

public interface StudentLessonRepository extends JpaRepository<StudentLesson, Long> {

    StudentLesson findById(Long id);

    StudentLesson findByStudentId(Long studentId);

    Long countByGradeAndLessonId(String grade, Long lessonId);

    List<StudentLesson> findByLessonIdAndGrade(Long id, String grade);

    List<StudentLesson> findByLessonId(Long lessonId);

    List<StudentLesson> findByStudentClass(String studentClass);
}
